home *** CD-ROM | disk | FTP | other *** search
/ Atari Mega Archive 1 / Atari Mega Archive - Volume 1.iso / lists / mint / l_0399 / 336 < prev    next >
Encoding:
Internet Message Format  |  1994-08-27  |  1.2 KB

  1. Date: Fri, 25 Jun 93 18:25:29 -0400
  2. From: "Nicholas S Castellano" <entropy@terminator.rs.itd.umich.edu>
  3. To: steve@earth.ox.ac.uk
  4. In-Reply-To: Stephen Usher's message of Fri, 25 Jun 1993 07:57:11 +0100 (BST) <26588.9306250657@earth.ox.ac.uk>
  5. Subject: nlink_t typedef, which is correct?
  6.  
  7. >In /usr/include/types.h (mntlib32) nlink_t is typedef'ed to short, whereas
  8. >in minixfs.h (part of the minix filesystem release 6.0.4) it's typedef'ed to
  9. >unsigned char.
  10. >
  11. >Both of these can't be correct, which one is?
  12.  
  13. The mint library is correct.  nlink_t is defined by POSIX as the type
  14. of st st_nlink element of struct stat.  This element is a short, not a
  15. char (actually it's supposed to be an unsigned short according to
  16. mint's file.h...oops...but it's still a word sized element).
  17.  
  18. Minixfs should use its own type (i suggest mnlink_t in the same way as
  19. it uses mgid_t for its internal version of a byte-sized gid) instead
  20. of the POSIX-reserved name nlink_t.
  21.  
  22. Actually it would be better if minixfs didn't define any names ending
  23. with _t as these are all reserved in the POSIX namespace. Perhaps
  24. nlink_mt, gid_mt, and so on would be better for all these internal
  25. types.
  26.  
  27. Cheers,
  28. entropy
  29.